package com.admin.controller;


import com.admin.entity.Region;
import com.admin.service.impl.RegionServiceImpl;
import com.bean.ResponseBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.List;


/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author marisheng
 * @since 2019-11-21
 */
@RestController
@RequestMapping("/admin/region")
public class RegionController {
    @Autowired
    private RegionServiceImpl regionService;

    /**
     * 区域查询
     * @return
     */
    @GetMapping("/SelectregionAll")
    public ResponseBean regionAll(){
        List<Region> list = regionService.regionAll();
        return new ResponseBean(200,"成功",list);
    }
}
